let MS = require('./ms.js')
const request = require('./request.js')
const {
    isString,
    isNumber,
    isUndefined,
    isArray,
    isBoolean
} = require('./dataType')

const noteLabel = class noteLabel {

    constructor() {

    }

    getNoteLabel(id) {
        let params = {
            noteLabelId: id
        }
        return new Promise((resolve, reject) => {
            request(MS._config.parameters.NOTE.GET_NOTE_LABEL.url,
                MS._config.parameters.NOTE.GET_NOTE_LABEL.method, params).then(res => {
                resolve(res.data)
            }).catch(err => {
                reject(err)
            })
        })
    }

    findNoteLabel() {
        return new Promise((resolve, reject) => {
            request(MS._config.parameters.NOTE.FIND_NOTE_LABEL.url,
                MS._config.parameters.NOTE.FIND_NOTE_LABEL.method).then(res => {
                resolve(res.data)
            }).catch(err => {
                reject(err)
            })
        })
    }
}

module.exports = noteLabel